//
//  ArticleCell.m
//  qiuShiJiangHu
//
//  Created by xalo on 16/1/25.
//  Copyright © 2016年 糗事江湖项目组. All rights reserved.
//

#import "ArticleCell.h"
#import "HomePageModel.h"
#import "UIImageView+WebCache.h"
@interface ArticleCell ()

@property (strong, nonatomic) IBOutlet UIImageView *iconImage;

@property (strong, nonatomic) IBOutlet UILabel *iconLabel;

@property (strong, nonatomic) IBOutlet UILabel *laughLabel;

@property (strong, nonatomic) IBOutlet UILabel *commentLabel;

@property (strong, nonatomic) IBOutlet UILabel *shareLabel;

@property (strong, nonatomic) IBOutlet UIButton *laughButton;

@property (strong, nonatomic) IBOutlet UIButton *unlaughButton;


@property (strong, nonatomic) IBOutlet UIButton *commentButton;



@end









@implementation ArticleCell

-(void)setContentViewWithModel:(HomePageModel *)model
{
    [self.iconImage sd_setImageWithURL:[NSURL URLWithString:model.icon] placeholderImage:[UIImage imageNamed:@"Icon@2x"]];
    self.iconLabel.text=model.login;
    self.contentLabel.text=model.content;
    self.laughLabel.text=[NSString stringWithFormat:@"%@",model.votes[@"up"]];
    self.commentLabel.text=[NSString stringWithFormat:@"%ld",model.comments_count];
    self.shareLabel.text=[NSString stringWithFormat:@"%ld",model.share_count];

    
}












- (IBAction)clickLaughButton:(UIButton *)sender {
}



- (IBAction)clickUnlaughButton:(UIButton *)sender {
}



- (IBAction)clickCommentButton:(UIButton *)sender {
}





- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
